package syntaxtree;

import visitor.IRTreeVisitor;
import visitor.Visitor;
import visitor.TypeVisitor;

public class If extends Statement {

    public Exp e;
    public Statement s1, s2;

    public If(Exp ae, Statement as1, Statement as2) {
        e = ae;
        s1 = as1;
        s2 = as2;
    }

    @Override
    public void accept(Visitor v) {
        v.visit(this);
    }

    @Override
    public Type accept(TypeVisitor v) {
        return v.visit(this);
    }

    @Override
    public Translate.Exp accept(IRTreeVisitor v) {
        return v.visit(this);
    }
}
